#ifndef MAINEDIT_H
#define MAINEDIT_H
#include <QLineEdit>
#include <QMouseEvent>

class MainEdit : public QLineEdit
{
    Q_OBJECT
public:
    MainEdit();
    explicit MainEdit(QWidget *parent = nullptr);
protected:
    //重写事件
    void mousePressEvent(QMouseEvent *event) override;
    void mouseReleaseEvent(QMouseEvent *event) override;
signals:
    void Slots_Click();
private:
    bool isMousePressed; // 用于记录鼠标是否按下
};

#endif // MAINEDIT_H
